#
# Be sure to run `pod lib lint SwiftAppKit.podspec' to ensure this is a
# valid spec before submitting.
#
# Any lines starting with a # are optional, but their use is encouraged
# To learn more about a Podspec see https://guides.cocoapods.org/syntax/podspec.html
#

Pod::Spec.new do |s|
  s.name = 'SwiftAppKit'
  s.version = '0.1.7'
  s.summary = 'Swift项目的框架库'

  # 1.私有仓库创建:远端创建一个空的git
  # 2. pod repo add iOS [远端仓库地址]
  # 3. pod lib create 本地库名
  # 4. 本地库正常打tag,推送到远端
  # 5. pod repo push iOS --sources=https://gitee.com/i-os-swift/specs.git,https://github.com/CocoaPods/Specs.git SwiftAppKit.podspec (推送本地库到私有仓库),
  # 保证s.verion 的版本在历史里有(源码打tag为s.version)
  # 上面的地址为repo地址底下引入第三方的repo地址(若存在私有库)
  # 如果直接推turn则使用pod trunk push SwiftAppKit.podspec
  #
  s.description = <<-DESC
  Swift项目的框架库,包括入口、网络、以及微服务设计等
  DESC

  s.homepage = 'https://gitee.com/i-os-swift/SwiftAppKit'
  # s.screenshots     = 'www.example.com/screenshots_1', 'www.example.com/screenshots_2'
  s.license = { :type => 'MIT', :file => 'LICENSE' }
  s.author = { 'Jeffrey' => 'jeffreyweiok@163.com' }
  s.source = { :git => 'https://gitee.com/i-os-swift/SwiftAppKit.git', :tag => s.version.to_s }

  s.ios.deployment_target = '11.0'
  s.swift_version = '5.7'
  s.subspec 'Core' do |s|
    s.source_files = 'SwiftAppKit/Classes/Core/*'
    s.dependency 'URLNavigator', '~> 2.4.1'
  end
  s.subspec 'Service' do |s|
    s.subspec 'RouterService' do |s|
      s.source_files = 'SwiftAppKit/Classes/Service/RouterService/*'
      s.dependency 'URLNavigator', '~> 2.4.1'
      s.dependency 'SwiftAppKit/Core'
    end
  end

  s.subspec 'Network' do |s|
    s.source_files = 'SwiftAppKit/Classes/Network/*'
    s.dependency 'Moya/RxSwift', '~> 15.0.0'
  end

  # s.resource_bundles = {
  #   'SwiftAppKit' => ['SwiftAppKit/Assets/*.png']
  # }

  # s.public_header_files = 'Pod/Classes/**/*.h'
  # s.frameworks = 'UIKit', 'MapKit'
  # s.dependency 'AFNetworking', '~> 2.3'
end
